#!/bin/sh
GREAT_PICTURE="die hard"
echo ${GREAT_PICTURE}

DOLLAR=99
echo $DOLLAR

COLOR=blue
echo "the sky is ${COLOR:?"can not locate COLOR"} today"
echo $COLOR

RO="hello"
echo $RO
#readonly RO
RO="world"
echo $RO



#vartest
echo "what time o you wish to start the payroll [03:00]"
#read TIME
echo "process to start at ${TIME:=03:00} OK"
echo "It is a monthly or weekly run [Weekly]:"
#read RUN_TYPE
echo "Run type is ${RUN_TYPE:=Weekly}"
at -f $RUN_TYPE $TIME

#echo "\n简单until 循环"
#IS_ROOT=`who | grep root`
#until [ "$IS_ROOT" ]
#do
#  sleep 1
#done
#echo "watch it. roots in "|mail simon

echo "监视文件"
LOCK_FILE=/tmpprocess.LCK
until [ ! -f $LOCK_FILE ]
do
  sleep 1
done
echo "file deleted"

echo "\n用while循环从文件中都去数据"
while read LINE
do
  echo $LINE
done < names.txt
#cat names.txt
